//
//  ArticleDetailModel.m
//  news_ios_app
//
//  Created by apple on 16/3/15.
//  Copyright © 2016年 apple. All rights reserved.
//

#import "ArticleDetailModel.h"

@implementation ArticleDetailModel
-(instancetype)init
{
    if (self = [super init]) {
        _content = nil;
    }
    return self;
}

+(instancetype)modelWithDictionary:(NSDictionary *)dictionary
{
    ArticleDetailModel *instance = [ArticleDetailModel new];
    if (!dictionary) {
        return nil;
    }
    if (![dictionary isKindOfClass:[dictionary class]]) {
        return nil;
    }
    
    if (!IsStrEmpty([dictionary objectForKey:@"content"])) {
        instance.content = [dictionary objectForKey:@"content"];
    }
    return instance;
}

- (instancetype)initWithDictionary:(NSDictionary *)dictionary
{
    self = [[self class]modelWithDictionary:dictionary];
    return self;
}

- (CGFloat)heightWithModel
{
//    if (![[self class] isKindOfClass:[ArticleDetailModel class]]) {
//        return 0;
//    }
    return 50.0f;
}

@end
